projects
/
emacs.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
3c69834
)
* gtkutil.c (get_utf8_string): Remove redundant assignment.
author
Paul Eggert
<eggert@cs.ucla.edu>
Mon, 25 Jun 2012 07:54:45 +0000
(
00:54
-0700)
committer
Paul Eggert
<eggert@cs.ucla.edu>
Mon, 25 Jun 2012 07:54:45 +0000
(
00:54
-0700)
sprintf already null-terminates its output.
src/ChangeLog
patch
|
blob
|
history
src/gtkutil.c
patch
|
blob
|
history
diff --git
a/src/ChangeLog
b/src/ChangeLog
index 3ad8c14fa2d2d1af52e1c746341381bf2512b2fa..5e9d60b13e078e624159b1307564c3c9274e5185 100644
(file)
--- a/
src/ChangeLog
+++ b/
src/ChangeLog
@@
-1,5
+1,8
@@
2012-06-25 Paul Eggert <eggert@cs.ucla.edu>
+ * gtkutil.c (get_utf8_string): Remove redundant assignment.
+ sprintf already null-terminates its output.
+
* xfns.c (x_window): Remove redundant cast.
2012-06-25 Dmitry Antipov <dmantipov@yandex.ru>
diff --git
a/src/gtkutil.c
b/src/gtkutil.c
index 51c56e49540ac51b16eb802ac6e5a25dcffd3e5e..6105d139d0ed07a94db196a3a988bc6493353e89 100644
(file)
--- a/
src/gtkutil.c
+++ b/
src/gtkutil.c
@@
-525,7
+525,6
@@
get_utf8_string (const char *str)
{
strncpy (up, (char *)p, bytes_written);
sprintf (up + bytes_written, "\\%03o", p[bytes_written]);
- up[bytes_written+4] = '\0';
up += bytes_written+4;
p += bytes_written+1;
g_error_free (err);